package com.sj.xmlanno;

import com.sun.org.apache.xpath.internal.operations.Or;

import javax.annotation.Resource;

public class BookService {

    //得到bookdao和ordersdao对象
    @Resource(name = "bookDao")
    private BookDao bookDao;

    @Resource(name = "ordersDao")
    private OrdersDao ordersDao;

    public void add() {
        System.out.println("bookService.............");
        bookDao.book();
        ordersDao.buy();
    }
}
